import request from '@/utils/request'
import type R from '@/types/conduit/R'
import type RiderSettings from '@/types/entity/RiderSettings'
import { type RiderSettingsUpdateParams } from '@/types/param/rider-settings'
export const queryRiderSettings = (): Promise<R<RiderSettings>> =>
  request({
    url: `/rider/rider-settings/query`,
    method: 'GET'
  })

export const update = (riderSettingsUpdateParams: RiderSettingsUpdateParams): Promise<R<RiderSettings>> =>
  request({
    url: `/rider/rider-settings/update`,
    method: 'POST',
    data: riderSettingsUpdateParams
  })
